import request from '@/utils/request'

// 查询活动报名记录列表(分页)
export function pageActivitySign (query) {
  return request({
    url: '/system/activitySign/page',
    method: 'get',
    params: query
  })
}
// 查询活动报名记录列表
export function listActivitySign (query) {
  return request({
    url: '/system/activitySign/list',
    method: 'get',
    params: query
  })
}

// 查询活动列表
export function listActivity (query) {
  return request({
    url: '/system/activitySign/activityList',
    method: 'get',
    params: query
  })
}

// 查询用户徽章列表
export function listUser (query) {
  return request({
    url: '/system/userBadge/userList',
    method: 'get',
    params: query
  })
}

// 查询活动报名记录详细
export function getActivitySign (id) {
  const params = {
    'id': id
  }
  return request({
    url: '/system/activitySign/getInfo',
    method: 'get',
    params: params
  })
}

// 新增活动报名记录
export function addActivitySign (data) {
  return request({
    url: '/system/activitySign/insert',
    method: 'post',
    data: data
  })
}

// 修改活动报名记录
export function updateActivitySign (data) {
  return request({
    url: '/system/activitySign/update',
    method: 'post',
    data: data
  })
}

// 删除活动报名记录
export function delActivitySign (id) {
  const params = {
    'id': id
  }
  return request({
    url: '/system/activitySign/delete',
    method: 'post',
    params: params
  })
}
// 批量删除活动报名记录
export function delBatchActivitySign (ids) {
  const params = {
    'ids': ids
  }
  return request({
    url: '/system/activitySign/deleteBatch',
    method: 'post',
    params: params
  })
}

// 导入活动报名记录
export function importData (data) {
  return request({
    url: '/system/activitySign/importData',
    method: 'post',
    data: data
  })
}
